Mirroring implementation
Hi,
I have a few questions concerning LVM mirror implementation, and I couldn't find any suitable design doc
I need to setup a dual site ( a few miles between the 2 sites, around 1 ms RTD) mirror based cluster system.
- what is the default behaviour of the mirroring, writing in parallel to both mirror legs or serialized ? what about read requests ?
- for write requests, is the ack returned to the application (thru VFS) when the 2 legs are updated or only when the first is updated ?
- Is there a way to control it ?
- what happens if the log device is lost ?
I saw a post about LVM mirror vs mdadm where it is about the location of the mirror log (
https://www.redhat.com/archives/linux-lvm/2009-July/msg00012.html) someone gave the answer that when creating the LV's with --alloc anywhere it will auto locate the log on any of the PV's.
According to what I could read, the --alloc doesn't intend for that, am I right ?
Brem ,
Quoted 5 lines · brem belguebli [[email protected]] wrote:
Hi,
I have a few questions concerning LVM mirror implementation, and I couldn't find any suitable design doc
I need to setup a dual site ( a few miles between the 2 sites, around 1 ms RTD) mirror based cluster system.
You need asynchronous mirroring (remote replication module). This is not in mainline (not sure if included in the latest RHEL release). The following comments apply to dm-mirror module that is already in the mainline.
Quoted 2 lines
- *what is the default behaviour of the mirroring, writing in parallel to both mirror legs or serialized ? what about read requests ?
It writes in parallel. Reads from a single device (switches on a device failure only).
Quoted 2 lines
- for write requests, is the ack returned to the application (thru VFS) when the 2 legs are updated or only when the first is updated ?
When two are updated. (you need 'remote replication' module for the latter behaviour)
Quoted 1 line
- Is there a way to control it ?
I don't think so.
Quoted 1 line
- what happens if the log device is lost ?
The mirror stops and a daemon re-allocates the log and the mirror should be back to business (this depends on your lvm configuration though).
Quoted 7 lines
I saw a post about LVM mirror vs mdadm where it is about the location of the mirror log ([1]https://www.redhat.com/archives/linux-lvm/2009-July/msg00012.html) someone gave the answer that when creating the LV's with --alloc anywhere it will auto locate the log on any of the PV's.
According to what I could read, the --alloc doesn't intend for that, am I right ?
Replace your "auto locate" to "allocate the log on any of the PV's".
What is the intention of the "--alloc anywhere" from your reading?
--Malahal.
Quoted 11 lines · On Mon, Jul 27, 2009 at 06:56:28AM -0700, [email protected] wrote:
Quoted 5 lines · brem belguebli [[email protected]] wrote:
Hi,
I have a few questions concerning LVM mirror implementation, and I couldn't find any suitable design doc
I need to setup a dual site ( a few miles between the 2 sites, around 1 ms RTD) mirror based cluster system.You need asynchronous mirroring (remote replication module). This is not in mainline (not sure if included in the latest RHEL release). The following comments apply to dm-mirror module that is already in the mainline.
There is also MD RAID1, see man mdadm, the --write-mostly and --write-behind options.
And of course, DRBD http://www.drbd.org
which is not RAID1 turned into replication,
but a dedicated replication solution.
Signature · 3 lines
: Lars Ellenberg : LINBIT | Your Way to High Availability : DRBD/HA support and consulting http://www.linbit.com
Hi Malahal,
2009/7/27, [email protected] <[email protected]>:
Quoted 6 lines
Quoted 4 lines · brem belguebli [[email protected]] wrote:
Hi,
I have a few questions concerning LVM mirror implementation, and I couldn't find any suitable design doc
I need to setup a dual site ( a few miles between the 2 sites, around
Quoted 7 lines
1 ms
Quoted 1 line
RTD) mirror based cluster system.
You need asynchronous mirroring (remote replication module). This is not in mainline (not sure if included in the latest RHEL release). The following comments apply to dm-mirror module that is already in the mainline.
Do you mean a Disk array based replication mechanism (SRDF, CA, etc...)? or is it system based , and if so do you have any technical document link to provide me ?
Quoted 7 lines
- *what is the default behaviour of the mirroring, writing in parallel
toQuoted 1 line
both mirror legs or serialized ? what about read requests ?
It writes in parallel. Reads from a single device (switches on a device failure only).
Quoted 6 lines
Quoted 1 line
- for write requests, is the ack returned to the application (thru
VFS)
Quoted 1 line
when the 2 legs are updated or only when the first is updated ?
When two are updated. (you need 'remote replication' module for the latter behaviour)
As I said, I couldn't find suitable doc about this, and in fact that's the behaviour I'm expecting (acking only when the 2 legs are up to date) . Can you point me to the good doc ?
Quoted 8 lines
- Is there a way to control it ?
I don't think so.
Quoted 1 line
- what happens if the log device is lost ?
The mirror stops and a daemon re-allocates the log and the mirror should be back to business (this depends on your lvm configuration though).
As the mirrorlog is in my case bound to a given SAN device (let's say /dev/sdx) and this device belongs to the SAN array located on the datacenter that experienced a disaster, my mirror won't be able to be brought back online as long as /dev/sdx is down .
Quoted 7 lines
I saw a post about LVM mirror vs mdadm where it is about the location
ofQuoted 2 lines
the mirror log ([1]https://www.redhat.com/archives/linux-lvm/2009-July/msg00012.html
)
Quoted 1 line
someone gave the answer that when creating the LV's with --alloc
anywhere
Quoted 8 lines
Quoted 2 lines
it will auto locate the log on any of the PV's.
According to what I could read, the --alloc doesn't intend for that,am I
Quoted 1 line
right ?
Replace your "auto locate" to "allocate the log on any of the PV's".
What is the intention of the "--alloc anywhere" from your reading?
According to the lvm man page, --alloc anywhere, in crontrary to --alloc strict (default) would allocate "data" LE to any pv forming the VG, resulting in having striped or mirrored LE on the same PV (sic!).
It doesn't seem to concern log device which is de facto a 3rd device not necessary belonging to the VG, or the man page is not up2date.
--Malahal.
Quoted 7 lines
_______________________________________________
linux-lvm mailing list
[email protected]
https://www.redhat.com/mailman/listinfo/linux-lvm
read the LVM HOW-TO at http://tldp.org/HOWTO/LVM-HOWTO/
Quoted 2 lines · On 27. juli. 2009, at 15.56, [email protected] wrote:
It writes in parallel. Reads from a single device (switches on a device failure only).
Wouldn't it be better to read in parallel, from different places? I've heard some controllers can do this, so that the reading will be somehow like reading from a RAID-0 stripe.
roy
--
Roy Sigurd Karlsbakk
(+47) 97542685
[email protected]
http://blogg.karlsbakk.net/
--
I all pedagogikk er det essensielt at pensum presenteres intelligibelt. Det er et element�rt imperativ for alle pedagoger � unng� eksessiv anvendelse av idiomer med fremmed opprinnelse. I de fleste tilfeller eksisterer adekvate og relevante synonymer p� norsk.
Hi Roy,
I would be better indeed, but practically, even if it is supposed to request both disks (san arrays) in //, the closest array will almost always be the first to answer unless it is overloaded.
What I'm looking for is the behaviour for writes, as I don't want to deal with failure scenarios in which I could find outdated data on my last remaining mirror leg.
2009/7/28, Roy Sigurd Karlsbakk <[email protected]>:
Quoted 31 lines · On 27. juli. 2009, at 15.56, [email protected] wrote:
It writes in parallel. Reads from a single device (switches on a device
Quoted 2 lines
failure only).
Wouldn't it be better to read in parallel, from different places? I've heard some controllers can do this, so that the reading will be somehow like reading from a RAID-0 stripe.
roy
--
Roy Sigurd Karlsbakk
(+47) 97542685
[email protected]
http://blogg.karlsbakk.net/
--
I all pedagogikk er det essensielt at pensum presenteres intelligibelt. Det er et elementært imperativ for alle pedagoger å unngå eksessiv anvendelse av idiomer med fremmed opprinnelse. I de fleste tilfeller eksisterer adekvate og relevante synonymer på norsk._______________________________________________
linux-lvm mailing list
[email protected]
https://www.redhat.com/mailman/listinfo/linux-lvm
read the LVM HOW-TO at http://tldp.org/HOWTO/LVM-HOWTO/